package com.sp.fresh_produce.service;

import com.github.pagehelper.PageInfo;
import com.google.zxing.WriterException;
import com.sp.fresh_produce.controller.dto.VO.OrderVO;
import com.sp.fresh_produce.controller.dto.req.CreateOrderReq;

import java.io.IOException;

public interface OrderService {
    String createOrder(Integer userId, CreateOrderReq createOrderReq);

    OrderVO detail(String orderNo);

    void cancel(String orderNo);

    String qrcode(String orderNo) throws IOException, WriterException;

    PageInfo listForAdmin(Integer pageNum, Integer pageSize);

    void pay(String orderNo);
    
    /**
     * 订单发货
     *
     * @param orderNo 订单号
     */
    void deliver(String orderNo);
}